package cn.com.myshiro.service;

import java.util.List;
import java.util.Map;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import cn.com.myshiro.bean.Userrole;
import  cn.com.myshiro.dao.UserroleDao;

@Service
 public class UserroleService {


   @Autowired
   UserroleDao dao;


   public List<Userrole> allUserrole(Map<Object,Object> map){
	     return dao.allUserrole(map);
   }

   public void delUserrole(int id){
	   dao.delUserrole(id);
   }

   public Userrole userrole(int id){
	   return dao.userrole(id);
   }

   public void updateUserrole(Userrole userrole){
	   dao.updateUserrole(userrole);
   }

   public void addUserrole(Userrole userrole){
   	dao.addUserrole(userrole);
   }

	public int countUserrole(){
		return dao.countUserrole();
	}
}
